home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
PC World Komputer 2010 April
/
PCWorld0410.iso
/
pluginy Firefox
/
9536
/
9536.xpi
/
chrome
/
commentsbar_ff.jar
/
content
/
commentsbar_ff
/
postinst.xul
< prev
next >
Wrap
Extensible Markup Language
|
2009-03-25
|
2KB
|
70 lines
<?xml version="1.0"?>
<?xml-stylesheet href="chrome://global/skin" type="text/css"?>
<dialog title=""
xmlns:html="http://www.w3.org/1999/xhtml"
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
buttons="accept,cancel"
ondialogaccept="return savesettings();"
>
<script>
<![CDATA[
/*var tool=null;
function ToolBarInit(maintool)
{
try{
tool = maintool;
}catch(e){alert(e);}
}
*/
function savesettings()
{
try{
if(document.getElementById("searchpage").checked)
{
var searchService =Components.classes["@mozilla.org/browser/search-service;1"].getService(Components.interfaces.nsIBrowserSearchService);
var engine=searchService.getEngineByName(name);
searchService.addEngine("https://www.commentsbar.com/ff/fast.src",2,"https://www.commentsbar.com/i/oneriot.gif",false);
Components.classes["@mozilla.org/preferences-service;1"].getService(Components.interfaces.nsIPrefBranch).setCharPref("browser.search.selectedEngine",name)
}
if(document.getElementById("homepage").checked)
{
Components.classes["@mozilla.org/preferences-service;1"].getService(Components.interfaces.nsIPrefBranch).setCharPref("browser.startup.homepage","http://www.commentsbar.com/home/?src=FF");
}
//tool.close_tbdefpagesdialog();
}catch(e){alert(e);}
}
function setText(textID,val)
{
document.getElementById(textID).value=val;
}
]]>
</script>
<groupbox flex="1">
<caption label="Settings" />
<checkbox flex="1" id="searchpage" value="a1" label="Make OneRiot social search engine your default." checked="true" />
<checkbox flex="1" id="homepage" value="a2" label="Make OneRiot your social homepage." checked="true" />
</groupbox>
</dialog>